package com.dmagic.cms.entity;

import java.io.Serializable;
import java.util.Date;

import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.TableGenerator;

import org.hibernate.annotations.Where;

import com.dmagic.cms.common.Constants;
import com.dmagic.cms.common.entity.ModifyInfoEntity;
import com.fasterxml.jackson.annotation.JsonAutoDetect;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;

@Entity
@Table(name = "dmagic_successful_case")
@Where(clause = ModifyInfoEntity.ISOBSOLETE_DATE_IS_NULL)
@JsonAutoDetect
@JsonIgnoreProperties(value = { "createdBy", "createdOn", "modifiedBy", "modifiedOn", "isObsoleteDate" })
public class SuccessfulCase extends ModifyInfoEntity implements Serializable {

	/**
     * 
     */
	private static final long serialVersionUID = 215425021278758153L;

	private Long successfulCaseId;

	private String successfulCaseNo;

	private String successfulCaseModel;

	private String successfulCaseName;

	private Long successfulCaseCategoryId;

	private Boolean successfulCaseStatus = false;

	private Long uploadFileSetInfoId;

	private String successfulCaseContent;

	private Date successfulCaseDate;

	private Boolean isTop = false;

	private Long languageId;

	public SuccessfulCase() {
		super();
	}

	@Id
	@GeneratedValue(strategy = GenerationType.TABLE, generator = Constants.ID_GENERATOR)
	@TableGenerator(name = Constants.ID_GENERATOR, // Generator Name which same
													// with
	// generator
	table = Constants.ID_GENERATOR, // Generator Table Name
	pkColumnName = Constants.PK_COLUMNNAME, // Generator Table column Id name
	valueColumnName = Constants.VALUE_COLUMN_NAME, // Generator Table column Id
													// value
	pkColumnValue = "SuccessfulCase", // entity Name
	allocationSize = (Constants.ID_GENERATOR_ALLLCATIONSIZE), initialValue = Constants.ID_GENERATOR_INITIALVALUE)
	public Long getSuccessfulCaseId() {
		return successfulCaseId;
	}

	public void setSuccessfulCaseId(Long successfulCaseId) {
		this.successfulCaseId = successfulCaseId;
	}

	public String getSuccessfulCaseNo() {
		return successfulCaseNo;
	}

	public void setSuccessfulCaseNo(String successfulCaseNo) {
		this.successfulCaseNo = successfulCaseNo;
	}

	public String getSuccessfulCaseModel() {
		return successfulCaseModel;
	}

	public void setSuccessfulCaseModel(String successfulCaseModel) {
		this.successfulCaseModel = successfulCaseModel;
	}

	public String getSuccessfulCaseName() {
		return successfulCaseName;
	}

	public void setSuccessfulCaseName(String successfulCaseName) {
		this.successfulCaseName = successfulCaseName;
	}

	public Long getSuccessfulCaseCategoryId() {
		return successfulCaseCategoryId;
	}

	public void setSuccessfulCaseCategoryId(Long successfulCaseCategoryId) {
		this.successfulCaseCategoryId = successfulCaseCategoryId;
	}

	public Boolean getSuccessfulCaseStatus() {
		return successfulCaseStatus;
	}

	public void setSuccessfulCaseStatus(Boolean successfulCaseStatus) {
		this.successfulCaseStatus = successfulCaseStatus;
	}

	public Long getUploadFileSetInfoId() {
		return uploadFileSetInfoId;
	}

	public void setUploadFileSetInfoId(Long uploadFileSetInfoId) {
		this.uploadFileSetInfoId = uploadFileSetInfoId;
	}

	@JsonIgnore
	public String getSuccessfulCaseContent() {
		return successfulCaseContent;
	}

	public void setSuccessfulCaseContent(String successfulCaseContent) {
		this.successfulCaseContent = successfulCaseContent;
	}

	public Date getSuccessfulCaseDate() {
		return successfulCaseDate;
	}

	public void setSuccessfulCaseDate(Date successfulCaseDate) {
		this.successfulCaseDate = successfulCaseDate;
	}

	public Boolean getIsTop() {
		return isTop;
	}

	public void setIsTop(Boolean isTop) {
		this.isTop = isTop;
	}

	public Long getLanguageId() {
		return languageId;
	}

	public void setLanguageId(Long languageId) {
		this.languageId = languageId;
	}

}
